package cn.iocoder.yudao.module.yyzx.dal.mysql.nurse_records;

import java.util.*;

import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.yudao.module.yyzx.dal.dataobject.nurse_records.Nurse_recordsDO;
import org.apache.ibatis.annotations.Mapper;
import cn.iocoder.yudao.module.yyzx.controller.admin.nurse_records.vo.*;

/**
 * 护理记录 Mapper
 *
 * @author lovedream
 */
@Mapper
public interface Nurse_recordsMapper extends BaseMapperX<Nurse_recordsDO> {

    default PageResult<Nurse_recordsDO> selectPage(Nurse_recordsPageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<Nurse_recordsDO>()
                .betweenIfPresent(Nurse_recordsDO::getNurseTime, reqVO.getNurseTime())
                .eqIfPresent(Nurse_recordsDO::getNurser, reqVO.getNurser())
                .eqIfPresent(Nurse_recordsDO::getElden, reqVO.getElden())
                .eqIfPresent(Nurse_recordsDO::getNurseDetails, reqVO.getNurseDetails())
                .eqIfPresent(Nurse_recordsDO::getNurseLevel, reqVO.getNurseLevel())
                .betweenIfPresent(Nurse_recordsDO::getCreateTime, reqVO.getCreateTime())
                .orderByDesc(Nurse_recordsDO::getId));
    }

}